
<script>
en4.core.runonce.add(function(){
    var id = 'field_list_country_body_<?php echo $this->country_id?>';
    var  el = $(id);
    if (typeof(el) == 'undefined' || el == null) return false;
    var position = el.getPosition();
    window.scrollTo(0,position.y);
    
})
</script>
<?php
    if ($this->error == true){
        echo "<div><span class='tip'>".$this->translate('Find not found your field.')." </span></div>";
        return;
    }
 ?>
 <?php if ($this->error == false) :?>
<div>
    <div class="field_title">
        <span class="field_title_title"><?php echo $this->translate('LISTING')?> :: <?php echo $this->fieldObject->title ?></span>
        <span class="field_title_print">Print</span>
    </div>
    <div class="field_description">
        <?php echo $this->fieldObject->description ?>
    </div>
    
    <div class="field_list_country">
        <table>
            
                <tr class="field_list_country_header">
                    <td class="field_list_country_header_country left"><?php echo $this->translate('COUNTRY'); ?></td>
                    <td class="field_list_country_header_detail"><?php echo $this->fieldObject->title ?></td>
                </tr>
            <?php $i = 0;?>
            <?php foreach($this->fields as $item): ?>
                <tr class="field_list_country_body <?php if($i%2 != 0)  echo "background"; $i++;  ?>">
                    <td class="left"> <a id="field_list_country_body_<?php echo $item->country_id?>" href="countries/views/<?php echo $item->country_id;?>" ><?php echo  $item->countryTitle; ?></a></td>
                    <td><?php echo $item->detail; ?></td>
                </tr>
            <?php endforeach; ?>
        </table>
    </div>
</div>
<?php endif; ?>